In a current AV system, a signal is often handled as a digital signal. The digital signal is more resistive to noises around it than an analog signal, and is reproduced satisfactorily when transmitted or recorded in a recording medium such as a CD (compact disc) or a DVD (digital video disc). When the digital data is stored in the recording medium or transmitted, in order to make it possible to store or transmit enormous amount of data, it is compressed. MPEG (Moving Picture Experts Group) is established as a standardization group for a compression technique. Among MPEG standards, MPEG1 and MPEG2 have been standardized as a compression method for a moving picture and MPEG-Audio has been standardized as a compression method for audio.
Hereinafter, conception of the compression technique for audio data according to MPEG-Audio standard or the like, will be described.
FIG. 19 is a block diagram showing a stereo using a compression and decompression technique for the digital audio data.
The stereo shown in FIG. 19 comprises a compression section 120 for compressing the digital audio data, and a decompression section 125 for restoring digital audio data from compressed data.
The compression section 120 comprises a band division (sub-band creating) unit 121, a psychoacoustic model 122, a bit allocation unit 123, and a bit stream generation unit 124. Since the digital audio data input to the compression section 120 is in a temporary domain, the band division unit 121 divides the digital audio data into sub-band data to transform it into digital data 151 in a frequency domain and outputs the digital data 151 to the psychoacoustic model 122 and the bit allocation unit 123. The psychoacoustic model 122 has a model showing a minimum level of audio perceived by human auditory sense, which generally employs a minimum audible limit on stillness or a masking characteristic relating to a background noise and the like. The psychoacoustic model 122 determines the number of bits to-be-allocated 152 of the digital data 151 with quantization precision of a masking level set considering a critical band according to the psychoacoustic model, and outputs the number of bits to-be-allocated 152 to the bit allocation unit 123. The bit allocation unit 123 performs bit allocation starting from an MSB (most significant bit) of the digital data 151 according to the number of bits to-be-allocated 152, thereby compressively coding the digital data 151. The resulting compressed data 103 and the number of allocated bits 152 are output from the bit allocation unit 123 to the bit stream generation unit 124. The bit stream generation unit 124 multiplexes the compressed data 103 and the number of allocated bits 152 to generate a bit stream, and records the bit stream in a storage medium.
When the stereo is used in a digital music broadcast apparatus, the bit stream can be sent to a channel such as the Internet.
The decompression section 125 comprises a bit stream decomposition unit 126, a bit decompression unit 127, and a band composition unit 128. The bit stream decomposition unit 126 decomposes the bit stream input to the decompression section 125 through the storage medium (channel) into compressed data 203 and a number of allocated bits 162, which are output to the bit decompression unit 127. The bit decompression unit 127 calculates a bit length of bits omitted by masking, from the number of bits of the digital data 151 and the number of allocated bits 162, generates data of the bit length, and couples the data to lower bits of the compressed data 203. The bit decompression unit 127 couples the bits omitted by the compression unit 120 to the lower bits of the compressed data 203, resulting in bit-decompressed digital data 161 of an original length. Since the bit-decompressed digital data 161 is data in the frequency domain, the band composition unit 128 transforms this data into data in the temporary domain, to restore original digital audio data.
Subsequently, compression and decompression operations of the digital audio data by the stereo will be described. Here it is assumed that "b"' is added before binary numbers in numeric representation.
In the compression section 120, the band division unit 121 divides the digital audio data in the temporary domain into sub-band data to transform it into the digital data 151 in the frequency domain. As an example of the digital data 151 output from the band division unit 121, "b' 10100100" of which the number of bits "8" is used. The number of bits "8" is predetermined as a fixed value. When the psychoacoustic model 122 decides that data transmission should be performed at a masking level of the number of bits "5", the bit allocation unit 123 allocates 5 bits starting from the MSB of the digital data 151 "b' 10100100", to create the compressed data 103 "b' 10100". The bit allocation unit 123 outputs the "b' 10100" as the compressed data 103 and "5" as the number of allocated bits 152 to the bit stream generation unit 124. The bit stream generation unit 124 multiplexes the compressed data 103 "b' 10100" and the number of allocated bits 152 "5", and records the bit stream in the storage medium such as the DVD.
Thus, in the compression section 120, the bit allocation unit 123 performs bit allocation of the digital data 151 to reduce the bits of the digital data 151 by unallocated bits, whereby the digital data 151 is compressed.
In the decompression section 125, the bit stream decomposition unit 126 decomposes the bit stream sent from the storage medium into the compressed data 203 "b' 101001", and the number of allocated bits 162 "5". In order to restore the digital data 151, the bit decompression unit 127 subtracts the number of allocated bits 162 "5" from the number of bits "8" of the digital data 151, to generate data "b' 000" of the number of bits "3" and couples the bits "b' 000", to a lower side of the compressed data 203 "b' 10100". The resulting bit-decompressed data 161 "b 10100000" is output from the bit decompression unit 127. Although the bit-decompressed data 161 "b' 10100000" is different from the digital data 151 "b' 10100100", difference between them is within an error which is hard for human ears to hear, and it is therefore assumed that these two signals are the same in practice. The digital data 161 output from the bit decompression unit 127 is transformed from data in the frequency domain into data in the temporary domain by the band composition unit 128, to restore the digital audio data.
Thus, in the decompression section 125, the bit decompression unit 127 couples omitted bits to the lower bits of the compressed data 203, whereby the bit-decompressed digital data 161 of the original length is obtained.
Further, since storage capacities of the storage media or communication capacities of channels are limited, there is a need for an improved compression technique as data capacities increase. In particular, as for the compression technique for the digital audio data, there is a need for a technique which further increases the compression ratio without degrading the audio quality.
However, using the conventional compression technique, like the stereo, it is impossible to encode the digital data 151 with bits fewer than the bits of the number of bits to-be-allocated 152 which is determined by the psychoacoustic model 122.